package ooday01;

import java.security.PublicKey;

public class Car {
    public String brand;
    public String color;
    public double price;

    //构造方法（无参）
    public Car(){

    }
    //构造方法(有参）
    public Car(String brand,String color,double price){
        this.brand=brand;
        this.color=color;
        this.price=price;
    }

    //成员方法
    public void start(){
        System.out.println(brand+"牌子的汽车,"+color+"颜色的"+price+"万元钱的汽车,启动了");
    }
    public void run(){
        System.out.println(brand+"牌子的汽车,"+color+"颜色的"+price+"万元钱的汽车,开始跑了");
    }
    public void stop(){
        System.out.println(brand+"牌子的汽车,"+color+"颜色的"+price+"万元钱的汽车,停止了");
    }

}
